package lad02.test06;

public class Circle {double radius;    //圆的半径
    double area;
    double perimeter;
    final double P = 3.1415926;

    public void setRadius(double radius) {
        this.radius = radius;
    }

    public double getRadius() {
        return radius;
    }

    public double getArea() {
        return (P * radius * radius);
    }

    public double getPerimeter() {
        return (2 * P * radius);
    }
}
